package com.example.zhihuhelpapp.bean;

import org.litepal.crud.DataSupport;

/**
 * 问题列表bean
 */
public class QuestionBean extends DataSupport {
    private String questionId;  // 问题id
    private String questionTitle;  // 问题标题
    private int questionAnswerCount;  // 问题下的回答个数
    private long updateTime; // 更新时间
    private int itemOrder;  // 排序
    private int top;  // 是否置顶 1--置顶  0--默认
    private int showRaking;  // 是否显示排名，0-不显示  1-显示
    private int answerRaking; // 回答的排名

    public String getQuestionId() {
        return questionId;
    }

    public boolean isTop(){
        return top == 1;
    }

    public void setQuestionId(String questionId) {
        this.questionId = questionId;
    }

    public String getQuestionTitle() {
        return questionTitle;
    }

    public void setQuestionTitle(String questionTitle) {
        this.questionTitle = questionTitle;
    }

    public int getQuestionAnswerCount() {
        return questionAnswerCount;
    }

    public void setQuestionAnswerCount(int questionAnswerCount) {
        this.questionAnswerCount = questionAnswerCount;
    }

    public int getAnswerRaking() {
        return answerRaking;
    }

    public void setAnswerRaking(int answerRaking) {
        this.answerRaking = answerRaking;
    }

    public long getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(long updateTime) {
        this.updateTime = updateTime;
    }

    public int getItemOrder() {
        return itemOrder;
    }

    public void setItemOrder(int itemOrder) {
        this.itemOrder = itemOrder;
    }

    public int getTop() {
        return top;
    }

    public void setTop(int top) {
        this.top = top;
    }

    public int getShowRaking() {
        return showRaking;
    }

    public void setShowRaking(int showRaking) {
        this.showRaking = showRaking;
    }

    @Override
    public String toString() {
        return "QuestionBean{" +
                "questionId='" + questionId + '\'' +
                ", questionTitle='" + questionTitle + '\'' +
                ", questionAnswerCount=" + questionAnswerCount +
                ", updateTime=" + updateTime +
                ", itemOrder=" + itemOrder +
                ", top=" + top +
                '}';
    }
}
